import request from '@/utils/request'

// 查询网关列表
export function listDtu(query) {
  return request({
    url: '/system/dtu/list',
    method: 'get',
    params: query
  })
}

// 查询网关详细
export function getDtu(id) {
  return request({
    url: '/system/dtu/' + id,
    method: 'get'
  })
}

// 新增网关
export function addDtu(data) {
  return request({
    url: '/system/dtu',
    method: 'post',
    data: data
  })
}

// 修改网关
export function updateDtu(data) {
  return request({
    url: '/system/dtu',
    method: 'put',
    data: data
  })
}

// 删除网关
export function delDtu(id) {
  return request({
    url: '/system/dtu/' + id,
    method: 'delete'
  })
}
